package cn.iocoder.yudao.module.handguard.dal.mysql.userbasetable7;

import java.util.*;

import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
import cn.iocoder.yudao.module.handguard.dal.dataobject.userbasetable7.UserBaseTable7DO;
import org.apache.ibatis.annotations.Mapper;
import cn.iocoder.yudao.module.handguard.controller.app.userbasetable7.vo.*;

/**
 * 全款车按揭车信贷 Mapper
 *
 * @author 芋道源码
 */
@Mapper
public interface UserBaseTable7Mapper extends BaseMapperX<UserBaseTable7DO> {

    default PageResult<UserBaseTable7DO> selectPage(UserBaseTable7PageReqVO reqVO) {
        return selectPage(reqVO, new LambdaQueryWrapperX<UserBaseTable7DO>()
                .eqIfPresent(UserBaseTable7DO::getUserId, reqVO.getUserId())
                .eqIfPresent(UserBaseTable7DO::getJob, reqVO.getJob())
                .betweenIfPresent(UserBaseTable7DO::getCreateTime, reqVO.getCreateTime())
                .orderByDesc(UserBaseTable7DO::getId));
    }

    default List<UserBaseTable7DO> selectList(UserBaseTable7ExportReqVO reqVO) {
        return selectList(new LambdaQueryWrapperX<UserBaseTable7DO>()
                .eqIfPresent(UserBaseTable7DO::getUserId, reqVO.getUserId())
                .eqIfPresent(UserBaseTable7DO::getJob, reqVO.getJob())
                .betweenIfPresent(UserBaseTable7DO::getCreateTime, reqVO.getCreateTime())
                .orderByDesc(UserBaseTable7DO::getId));
    }

}
